﻿<%@ Page Language="VB" MasterPageFile="~/msrAdministrator.master" AutoEventWireup="false" CodeFile="UC04-070.aspx.vb" Inherits="_114_UC04_070" %>
<asp:Content id="ctUC04070" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    &nbsp;&nbsp;
    <br />
    <br />
    <table>
        <tr>
            <td align="center" style="width: 100px; height: 22px">
    <asp:Label ID="Label1" runat="server" Font-Bold="True" Text="Quản Lý Linh Kiện" Width="595px" Font-Size="Larger" ForeColor="Blue"></asp:Label></td>
        </tr>
        <tr>
            <td style="width: 100px; height: 248px">
                &nbsp;<asp:GridView ID="GridView1" runat="server" Height="270px" Width="599px" AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False" CellPadding="4" DataSourceID="SqlDataSource1" ForeColor="#333333" GridLines="None" PageSize="15">
                    <PagerSettings FirstPageText="First" LastPageText="Last" NextPageText="Next" PreviousPageText="Previous" />
                    <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                    <RowStyle BackColor="#EFF3FB" />
                    <EditRowStyle BackColor="#2461BF" />
                    <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#FF8000" />
                    <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
                    <HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                    <AlternatingRowStyle BackColor="White" />
                </asp:GridView>
                <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:HAIDANG_DATABASEConnectionString %>"
                    DeleteCommand="DELETE FROM [LINHKIEN] WHERE [MaLK] = @MaLK" InsertCommand="INSERT INTO [LINHKIEN] ([MaLK], [MaLoaiLK], [ThongTinNhaSX], [ThoiGianBaoHanh], [Gia], [CauHinh], [SoLuongTon]) VALUES (@MaLK, @MaLoaiLK, @ThongTinNhaSX, @ThoiGianBaoHanh, @Gia, @CauHinh, @SoLuongTon)"
                    SelectCommand="SELECT LINHKIEN.MaLK, LOAILK.TenLK, LINHKIEN.ThongTinNhaSX, LINHKIEN.ThoiGianBaoHanh, LINHKIEN.Gia, LINHKIEN.CauHinh, LINHKIEN.SoLuongTon FROM LINHKIEN INNER JOIN LOAILK ON LINHKIEN.MaLoaiLK = LOAILK.MaLoaiLK"
                    UpdateCommand="UPDATE [LINHKIEN] SET [MaLoaiLK] = @MaLoaiLK, [ThongTinNhaSX] = @ThongTinNhaSX, [ThoiGianBaoHanh] = @ThoiGianBaoHanh, [Gia] = @Gia, [CauHinh] = @CauHinh, [SoLuongTon] = @SoLuongTon WHERE [MaLK] = @MaLK">
                    <DeleteParameters>
                        <asp:Parameter Name="MaLK" Type="Int64" />
                    </DeleteParameters>
                    <UpdateParameters>
                        <asp:Parameter Name="MaLoaiLK" Type="String" />
                        <asp:Parameter Name="ThongTinNhaSX" Type="String" />
                        <asp:Parameter Name="ThoiGianBaoHanh" Type="String" />
                        <asp:Parameter Name="Gia" Type="Double" />
                        <asp:Parameter Name="CauHinh" Type="String" />
                        <asp:Parameter Name="SoLuongTon" Type="Int16" />
                        <asp:Parameter Name="MaLK" Type="Int64" />
                    </UpdateParameters>
                    <InsertParameters>
                        <asp:Parameter Name="MaLK" Type="Int64" />
                        <asp:Parameter Name="MaLoaiLK" Type="String" />
                        <asp:Parameter Name="ThongTinNhaSX" Type="String" />
                        <asp:Parameter Name="ThoiGianBaoHanh" Type="String" />
                        <asp:Parameter Name="Gia" Type="Double" />
                        <asp:Parameter Name="CauHinh" Type="String" />
                        <asp:Parameter Name="SoLuongTon" Type="Int16" />
                    </InsertParameters>
                </asp:SqlDataSource>
            </td>
        </tr>
    </table>
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    
   
</asp:Content>